using System.ComponentModel.DataAnnotations;
using System.Data.Entity.ModelConfiguration;
using Planisoft.Entities;


namespace Planisoft.DAO.Mapping
{
    public class UbigeoProvinciaMap : EntityTypeConfiguration<UbigeoProvincia>
    {
        public UbigeoProvinciaMap()
        {
            // Primary Key
            this.HasKey(t => t.IdUbiProv);

            // Properties
            this.Property(t => t.CodPdtUbiProv)
                .HasMaxLength(10);

            // Table & Column Mappings
            this.ToTable("UbigeoProvincia");
            this.Property(t => t.IdUbiProv).HasColumnName("IdUbiProv");
            this.Property(t => t.CodPdtUbiProv).HasColumnName("CodPdtUbiProv");
            this.Property(t => t.DescUbiProv).HasColumnName("DescUbiProv");
        }
    }
}
